import random
with open("ips.txt",mode='w+') as ip:
    for i in range(0,120000):
        ip.write ("172.25.254.{0}\n".format(random.randrange(0,255)))
with open("ips.txt",mode="r") as ip:
    iplist=ip.read().splitlines()
    ipset=set(iplist)
ipdic=dict()
for i in ipset:
    ipc = iplist.count(i)
    dic={i:ipc}
    ipdic.update(dic)
order=sorted(ipdic.items(),key=lambda x:x[1],reverse=True)
for i in range(0,10):
    print("TOP{0}: ADDR:{1} TIMES:{2}".format(i+1,order[i][0],order[i][1]))